import java.util.Random;
import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        //猜数字
        Scanner scanner=new Scanner(System.in);
        Random random=new Random();

        int ranNUm = random.nextInt(11)+10;
        while (true){
            System.out.println("请输入一个数字：");
            int num=scanner.nextInt();
            if(num < ranNUm){
                System.out.println("猜小了！");
            } else if (num == ranNUm)  {
                System.out.println("猜对了1");
                break;
            }else {
                System.out.println("猜大了!");
            }
        }
    }
}